Conversation
Caught this adding algolia - we're generating links without the trailing slash which is fine client side but with GitHub pages results in a redirect to the URL with a trailing slash in direct HTTP requests.
There was a problem hiding this comment.
Pull request overview
This PR updates the Docusaurus site configuration to avoid GitHub Pages redirects by ensuring generated site links include trailing slashes.
Changes:
- Enable
trailingSlash: truein the Docusaurus config to generate URLs with trailing slashes.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| // Set the /<baseUrl>/ pathname under which your site is served | ||
| // For GitHub pages deployment, it is often '/<projectName>/' | ||
| baseUrl: '/clusterscope', | ||
|
|
||
| // GitHub pages deployment config. | ||
| // If you aren't using GitHub pages, you don't need these. | ||
| organizationName: 'facebookresearch', // Usually your GitHub org/user name. | ||
| projectName: 'clusterscope', // Usually your repo name. | ||
| trailingSlash: true, |
There was a problem hiding this comment.
baseUrl is set to '/clusterscope' (no trailing /), but the surrounding comment indicates it should be '/<projectName>/'. With trailingSlash: true (and on GitHub Pages), leaving baseUrl without a trailing slash can still cause an extra redirect for the site root and may lead to inconsistent URL joining. Consider updating baseUrl to '/clusterscope/' to fully eliminate trailing-slash redirects and align with Docusaurus’ expected format.
Caught this adding algolia - we're generating links without the trailing slash which is fine client side but with GitHub pages results in a redirect to the URL with a trailing slash in direct HTTP requests.